﻿/// <reference path="../jquery.min.js" />
/// <reference path="../module/rsseasy.v2.js" />

$(function () {
    var myorderitempage = $("#myorderitempage");
    myorderitempage.load(function () {
        RssApi.Table.List("order_info").setLoading().condition(new RssDict().keymyid().getDict()).getJson(function (json) {
            myorderitempage.find("tbody").mapview(json, {
                "shijian": function (val) {
                    return new Date(val * 1000).toString("yyyy-MM-dd HH:mm:ss");
                },
                "fee": function (val) {
                    return val.tomoney(); //格式化金额
                },
                "channelid": function (val) {
                    return RssPay.Channel[val];
                }
            }).on("click", "span", function () {
                var t = $(this), rssid = t.attr("rssid");

                new Ajax("order/refund").setLoading(true).keymyid().keyvalue("orderid", rssid).getJson(function () {

                });
            });
        });
    });
});